package home.main.util;

import home.main.entity.Product;

import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.ArrayList;
import java.util.List;

import jxl.read.biff.BiffException;

public class Controller {
	
	private URL url;
	private ArrayList<Product> listProducts = new ArrayList<Product>();
	
	public URL getUrl() {
		return url;
	}

	public void setUrl(String url) {
		try {
			this.url = new URL(url);
		} catch (MalformedURLException e) {
			e.printStackTrace();
		}
	}

	
	
	public List<Product> getProductFromXLS() throws BiffException, IOException {

		String fileName = "Deuter 2012.xls";
		XLSReader xlsReader = new XLSReader(fileName);
//		return xlsReader.getListProducts();
		return null;
	}
	
	public List<Product> getProductsFromSite(List<Product> listProducts ){
		
//			SiteReader siteReader = new SiteReader();
//			siteReader.readDate(listProducts);
			
		return null;
	}
	
}
